<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <meta name="author" content="纪德朝">
    <title>改变透明度</title>
    <style>
    div{
        width: 700px;
        height: 300px;
        margin: 50px auto;
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        border: 2px solid black;
    }
    li{
        list-style: none;
        opacity: 0.5;
    }
    li:hover{
        opacity: 1;
    }
</style>
</head>
<body>
    <div>
        <li><img src="img/1.jpg" alt=""></li>
        <li><img src="img/2.jpg" alt=""></li>
        <li><img src="img/3.jpg" alt=""></li>
        <li><img src="img/4.jpg" alt=""></li>
        <li><img src="img/5.jpg" alt=""></li>
        <li><img src="img/6.jpg" alt=""></li>
        <li><img src="img/7.jpg" alt=""></li>
        <li><img src="img/8.jpg" alt=""></li>
        <li><img src="img/9.jpg" alt=""></li>
        <li><img src="img/10.jpg" alt=""></li>
    </div>
</body>
<script>
    
</script>
</html>